<!DOCTYPE html>
<!--suppress ALL -->
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 
	<title>借款申请</title>
<link rel="stylesheet" type="text/css" th:href="@{/css/style.css}">
<!-- <link rel="stylesheet/less" type="text/css" href="css/style.less" /> -->
<script type="text/javascript" th:src="@{/js/jquery-1.7.2.min.js}"></script>
<script type="text/javascript" th:src="@{/js/all.js}"></script>
<!--[if IE 6]> 
<script th:src="@{/js/iepng.js}" type="text/javascript"></script>
<script type="text/javascript">
   EvPNG.fix('div, ul, img, li, input,span, p');
</script>
<![endif]-->
</head>
<body>

<!-- end banner -->
<div class="bor_con_wper" id="app">
	  <div class="bor_con px1000">
	  	    <div class="bor_detail">
	  	    	   <h2 class="bor_detail_tit">
					   <span>我要贷款</span>
					   <span style="margin-left: 200px">我要发散标</span>

	  	    	   </h2>
	  	    	   <div class="bor_detail_box">
	  	    	   	    <div class="bor_det_one clearfix pt30 pb30">
	  	    	   	    	  <div class="bor_det_onel fl">
	  	    	   	    	  	       <p class="bor_p1">中兴财富平台的借款功能旨在帮助借款用户以
										低成本获得借款。用户在需要资金时，可以将
										自有房产和车产作为抵押物，小油菜线下审核
										通过后，根据抵押物的价值融资。</p>
										<p class="bor_p2">中兴财富平台的借款功能旨在帮助借款用户以
										低成本获得借款。用户在需要资金时，可以将
										自有房产和车产作为抵押物，小油菜线下审核
										通过后，根据抵押物的价值融资。</p>
										<h3 class="bor_onel_tit"><span>申请条件</span></h3>
										<ul class="bor_onel_ul">
											 <li><img src="images/bor_pic01.png" alt="">年满18周岁以上的公民
											 </li>
											 <li><img src="images/bor_pic02.png" alt="">需要北京房产或车产抵押
											 </li>
											 <li><img src="images/bor_pic03.png" alt="">个人或企业银行征信记录良好
											 </li>
											 <li><img src="images/bor_pic04.png" alt="">
											  无现有诉讼记录
											 </li>
											 
										</ul>
										<h3 class="bor_onel_tit"><span>提交资料</span></h3>
										<ul class="bor_onel_ul">
											 <li>&nbsp;<img src="images/bor_pic05.png" alt="">省份证
											 </li>
											 <li><img src="images/bor_pic06.png" alt="">申请资料
											 </li>
											 <li><img src="images/bor_pic07.png" alt="">其他
											 </li>
											
											 
										</ul>
	  	    	   	    	  </div>  
	  	    	   	    	  <!-- end l -->
	  	    	   	    	  <div class="bor_det_oner fl">
	  	    	   	    	  	     <form th:action="@{/debtor/apply}">
	  	    	   	    	  	     	  <fieldset>
	  	    	   	    	  	     	  	   <div>
	  	    	   	    	  	     	  	   	   <label>申请人</label>
	  	    	   	    	  	     	  	   	   <input type="" name="debtorname" :value="username" readonly>
	  	    	   	    	  	     	  	   </div>
	  	    	   	    	  	     	  	   <div class="mt15">
	  	    	   	    	  	     	  	   	   <label>*借款金额</label>
	  	    	   	    	  	     	  	   	   <input type=""  name="debtormoney" required pattern="(^[0-9]*[1-9][0-9]*$)" title="请输入0-9位数字">
	  	    	   	    	  	     	  	   </div>
                                               <div class="mt15">
	  	    	   	    	  	     	  	   	   <label>*借款期限</label>
	  	    	   	    	  	     	  	   	   <input type="" class="bor_inputbg02" name="debtordays">
	  	    	   	    	  	     	  	   </div>
	  	    	   	    	  	     	  	   <div class="mt15">
	  	    	   	    	  	     	  	   	   <label>*手机号码</label>
	  	    	   	    	  	     	  	   	   <input type=""  name="debtorphone" required pattern="(\d{11})|^((\d{7,8})|(\d{4}|\d{3})-(\d{7,8})|(\d{4}|\d{3})-(\d{7,8})-(\d{4}|\d{3}|\d{2}|\d{1})|(\d{7,8})-(\d{4}|\d{3}|\d{2}|\d{1}))$" title="请输入正确的手机号">
	  	    	   	    	  	     	  	   </div>
	  	    	   	    	  	     	  	   <!--<div class="mt15 guarmethod clearfix">
	  	    	   	    	  	     	  	   	   <label class="guarmethod_l fl">*担保方式</label>
	  	    	   	    	  	     	  	   	   <div class="fl">
	  	    	   	    	  	     	  	   	   	  <span>房屋数量</span>
	  	    	   	    	  	     	  	   	   	  <input type="text" class="bor_inputbg03 input2" name="num"><br><br>
	  	    	   	    	  	     	  	   	   	  <span>总价值</span>
	  	    	   	    	  	     	  	   	   	  <input type="text" class="bor_inputbg04 input2" name=""><br>
	  	    	   	    	  	     	  	   	   </div>
	  	    	   	    	  	     	  	   	   
	  	    	   	    	  	     	  	   </div>-->
											  <div class="mt15">
												  <label>*还款方式</label>
												  <select name="debtorstyle">
													  <option>分期还款</option>
													  <option>到期一次还本付息</option>
												  </select>
											  </div>
	  	    	   	    	  	     	  	   <div class="mt15">
	  	    	   	    	  	     	  	   	   <label>*担保方式</label>
	  	    	   	    	  	     	  	   	   <select name="debtortype">
	  	    	   	    	  	     	  	   	   	  <option>房屋</option>
													   <option>车辆</option>
													   <option>信用</option>
													   <option>混合抵押</option>
	  	    	   	    	  	     	  	   	   </select>
	  	    	   	    	  	     	  	   </div>
											  <div class="mt15">
												  <label>*借款用途</label>
												  <input type="" name="debtoruser">

											  </div>
	  	    	   	    	  	     	  	    <div class="mt15">
	  	    	   	    	  	     	  	   	   <label>*借款描述</label> 
	  	    	   	    	  	     	  	   	   <textarea name="debtordesc"></textarea>
	  	    	   	    	  	     	  	   	 
	  	    	   	    	  	     	  	   </div>
	  	    	   	    	  	     	  	   <div class="mt15">
	  	    	   	    	  	     	  	   	   <label>*借款情况</label>
	  	    	   	    	  	     	  	   	   <input type="radio" class="input3"value="普通借款" name="debtorinfo">
	  	    	   	    	  	     	  	   	   普通借款
	  	    	   	    	  	     	  	  	   <input type="radio" class="input3" value="紧急借款" name="debtorinfo">
	  	    	   	    	  	     	  	   	   紧急借款 
	  	    	   	    	  	     	  	   </div>
	  	    	   	    	  	     	  	   <div class="mt30">
	  	    	   	    	  	     	  	   	   <label></label>
	  	    	   	    	  	     	  	   	   <!--<a href="javascript:void(0)" class="bor_btn">提交材料</a>-->
												   <!--<input type="submit" class="bor_btn" th:value="提交材料">-->
												   <button class="bor_btn" >提交材料</button>
	  	    	   	    	  	     	  	   </div>
	  	    	   	    	  	     	  </fieldset>
	  	    	   	    	  	     </form>
								  <h3 th:if="msg!=null" style="font-size: 20px;color: red;margin-top: 10px" >[[${msg}]]</h2>
	  	    	   	    	  </div>
	  	    	   	    </div>


		  <!-- end 房产抵押 -->
						  <div class="bor_det_one" style="display:none;" >
							  <div class="bor_det_one1 f1"  style="width: 200px">
								  <p class="bor_p1">中兴财富平台的借款功能旨在帮助借款用户以
									  低成本获得借款。用户在需要资金时，可以将
									  自有房产和车产作为抵押物，小油菜线下审核
									  通过后，根据抵押物的价值融资。</p>
								  <p class="bor_p2">中兴财富平台的借款功能旨在帮助借款用户以
									  低成本获得借款。用户在需要资金时，可以将
									  自有房产和车产作为抵押物，小油菜线下审核
									  通过后，根据抵押物的价值融资。</p>
								  <h3 class="bor_onel_tit"><span>申请条件</span></h3>
								  <ul class="bor_onel_ul">
									  <li><img src="images/bor_pic01.png" alt="">年满18周岁以上的公民
									  </li>
									  <li><img src="images/bor_pic02.png" alt="">需要北京房产或车产抵押
									  </li>
									  <li><img src="images/bor_pic03.png" alt="">个人或企业银行征信记录良好
									  </li>
									  <li><img src="images/bor_pic04.png" alt="">
										  无现有诉讼记录
									  </li>

								  </ul>
								  <h3 class="bor_onel_tit"><span>提交资料</span></h3>
								  <ul class="bor_onel_ul">
									  <li>&nbsp;<img src="images/bor_pic05.png" alt="">省份证
									  </li>
									  <li><img src="images/bor_pic06.png" alt="">申请资料
									  </li>
									  <li><img src="images/bor_pic07.png" alt="">其他
									  </li>
								  </ul>

							  </div>

						<div class="bor_det_oner f1" style="position: relative;left:350px;top: -530px">
								  <form th:action="@{/LooseLabelWEB/add}" method="post"  enctype="multipart/form-data">
									  <fieldset>
										  <div>
											  <label>申请人</label>
											  <input type="text" name="debtorname" :value="username" readonly>
										  </div>
										  <div class="mt15">
											  <label>*借款金额</label>
											  <input type="text"  name="debtormoney" required pattern="(^[0-9]*[1-9][0-9]*$)" title="请输入0-9位数字">
										  </div>
										  <div class="mt15">
											  <label>*借款期限</label>
											  <input type="number" name="debormoney" min="1" max="36" class="bor_inputbg02">
										  </div>

										  <div class="mt15">
											  <label>*手机号码</label>
											  <input type="text"name ="phone" id="phones" required pattern="(\d{11})|^((\d{7,8})|(\d{4}|\d{3})-(\d{7,8})|(\d{4}|\d{3})-(\d{7,8})-(\d{4}|\d{3}|\d{2}|\d{1})|(\d{7,8})-(\d{4}|\d{3}|\d{2}|\d{1}))$" title="请输入正确的手机号">
										  </div>
										  <div class="mt15 guarmethod clearfix">
											  <label class="guarmethod_l fl">*担保方式</label>
											  <select name="loanmode" >
												  <option value="房屋抵押">默认房屋抵押</option>
												  <option value="车辆抵押">车辆抵押</option>
												  <option value="房屋抵押">房屋抵押</option>
												  <option value="信用">信用</option>
											  </select>
										  </div>
										  <div class="mt15 guarmethod clearfix">
											  <label class="guarmethod_l fl">*还款方式</label>
											  <select name="repaymentmethod" placeholder="默认等额本息">
												  <option value="等额本息">默认等额本息</option>
												  <option value="等额本息">等额本息</option>
												  <option value="等额本金">等额本金</option>
											  </select>
										  </div>
										  <div class="mt15 guarmethod clearfix">
											  <label class="guarmethod_l fl">*预期利率</label>
											  <select name="incomerate"  placeholder="请选择" >
												  <option value="0.00045">日利率万分之4.5</option>
												  <option value="0.00050">日利率万分之5.0</option>
												  <option value="0.00053">日利率万分之5.3</option>
											  </select>
										  </div>
										  <div class="mt15">
											  <label>*借款用途</label>
											  <input type="text" name="debtoruser">
										  </div>
										  <div class="mt15">
											  <label>*借款描述</label>
											  <textarea name="debtordesc"></textarea>
										  </div>
										  <div class="mt15" >
											  <label>*验证码</label>
											  <input type="text" class="yanzheng" name="code" >
											  <input type="button"  width="225px" class="obtain generate_code" value=" 获取验证码" id="codes" onclick="settime(this)">
										  </div>
										  <div class="mt15" >
											  <label>*上传资料</label>
											  <input type="file" name="debtortypedesc">
										  </div>
										  <div class="mt30">
											  <label></label>
											  <button type="submit" class="bor_btn"value="提交材料">提交材料</button>
										  </div>
									  </fieldset>
								  </form>
								  <h2 th:if="results!=null" style="font-size: 20px;color: red;margin-top: 10px" >[[${results}]]</h2>
					  </div>
							  <!-- end l -->
	  	    	   	    </div>
	  	    	   </div>
	  	    </div>
	  </div>
</div>
<script th:src="@{/js/vue.js}"></script>
<script th:src="@{/js/jquery-1.7.2.min.js}"></script>
<script>
	var countdown=60;
	function f(val) {
		if (countdown == 0) {
			val.removeAttribute("disabled");
			val.value="获取验证码";
			countdown = 60;
			return false;
		} else {
			val.setAttribute("disabled", true);
			val.value="重新发送(" + countdown + ")";
			countdown--;
		}setTimeout(function() {
			settime(val);
		},1000);
	}
	function settime(val) {
		if (countdown==60) {
			let phone = $("#phones").val();
			$.ajax({
				url:"[[@{/LooseLabelWEB/code}]]",
				data:{"phone":phone},
				dataType:"json",
				type:"get",
				success:function (date) {
					if (date.code==200){
						alert(date.msg);

					} else{
						alert(date.msg);
					}
				}
			})}
		f(val);
	}

$(function () {
	vue.queryusername();
})
let vue =new Vue({
	el:"#app",
	data: {
		username:"",
	},
	methods:{
		queryusername(){
			$.ajax({
				url:"[[@{/indexweb/username}]]",
				dataType:"json",
				type:"get",
				success:function (data) {
					console.log(data)
				vue.username=data.data;
				}
			})
		}
	}
})

</script>
</body>
</html>